home *** CD-ROM | disk | FTP | other *** search
- /* */
- /* download.rexx */
- /* */
- /* This ARexx program can be used for automatic */
- /* download from Calvacom */
- /* */
- /* */
- /* SYNTAX : */
- /* */
- /* rx download CITE/BIB/SECTION/PROGRAMME file */
- /* */
- /* */
- /* EXAMPLES : */
- /* */
- /* - Download dme.zip from AMIGA CITY in BIB AMIGA, section */
- /* UTILITIES, and save it as dh0:calva/new_dme.zip */
- /* */
- /* rx download amiga/amiga/utilitaires/dme.zip dh0:calva/new_dme.zip */
- /* */
- /* - Downloading FOO from MAC City, SECTION INIT */
- /* (there is not sub-section in Cité Mac !!!) */
- /* */
- /* rx download mac//init/foo ram:foo.mac */
- /* */
- /* */
- /* BUGS : */
- /* */
- /* There are no tests on the answers returned by Calva or by */
- /* the modem. To be safe, memory should be used, and values */
- /* found in this variable should be tested */
- /* */
- /* */
- /* NOTES : */
- /* */
- /* We could have starte with "console_close", this would have */
- /* closed the console window, though speeding up the script */
- /* (there would have been nothing to print on the screen) */
-
- arg cite '/' bib '/' section '/' programme ' ' fichier
-
- say "cite = " cite
- say "bib = " bib
- say "section = " section
- say "programme = " programme
- say "fichier = " fichier
-
- address TERM
-
- serial_send '"ATDT16143061111\n"'
- rexx_delay 5; rexx_wait 30 1
- rexx_wait 5 1
- serial_send '"eg19\n"'
- rexx_wait 5 1
- serial_send '"password\n"'
- rexx_wait 5 1
- serial_send '"'"CI" cite"\n"'"'
- rexx_wait 5 1
- serial_send '"'"BIB" bib"\n"'"'
- rexx_wait 5 1
- serial_send '"'section"\n"'"'
- rexx_wait 5 1
- xpr_open '"xprxmodem.library"'
- xpr_init '"T0,C0,K1"'
- serial_send '"'"im" programme"\n"'"'
- rexx_wait 5 1
- serial_send '"Y\n"'
- rexx_wait 5 1
- xpr_receive '"'fichier'"'
- serial_send '"!!\n"'
- rexx_delay 2
- serial_send '"!!\n"'
- rexx_wait 5 1
- serial_send '"+++"'
- rexx_delay 1
- serial_send '"ATH\n"'
-
-
-